#include <stdio.h>
#include <string.h>

int main(int argc, const char *argv[])
{
	char s1[20] = "hello";
	char s2[20] = "halloabc";

	int ret = strcmp(s1, s2);
	if(ret == 0){
		printf("s1 == s2\n");
	}else if(ret > 0){
		printf("s1 > s2\n");
	}else if(ret < 0){
		printf("s1 < s2\n");
	}

	// 了解：返回值本质是s1和s2中第一个不相等字符的ascii码的差值 s1-s2
	printf("ret = %d\n", ret);

	return 0;
}
